/*
 * Copyright (c) $today.year-Now http://www.zxpnet.com All rights reserved.
 */

package com.zxp.springboot.config;

import com.zxp.springboot.interceptor.AuthInterceptor;
import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;

/**
 * @author: shollin
 * @date: 2021/6/30/030 23:15
 */
//@Configuration
public class WebConfig implements WebMvcConfigurer {


    @Override
    public void addInterceptors(InterceptorRegistry registry) {

        AuthInterceptor authInterceptor = new AuthInterceptor();
        registry.addInterceptor(authInterceptor).excludePathPatterns("/login","/images/**","/","/layuimini/**","/assets/**","/auth/**");

        WebMvcConfigurer.super.addInterceptors(registry);
    }
}
